package com.peas.platform.module.icims.base.sys.adapter.repository.po;

import java.util.*;
import java.math.*;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.peas.platform.framework.mybatisplus.po.BasePo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.ibatis.type.JdbcType;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

// 接口调用记录
@Data
@EqualsAndHashCode(callSuper = false)
@TableName(value = "`tbl_invoke`")
public class InvokePo extends BasePo {

    //系统
    @Size(max = 100, message = "系统不能超过100个字符")
    @TableField(value = "`system`", jdbcType = JdbcType.VARCHAR)
    private String system;

    //系统名称
    @Size(max = 100, message = "系统名称不能超过100个字符")
    @TableField(value = "`system_name`", jdbcType = JdbcType.VARCHAR)
    private String systemName;

    //服务
    @Size(max = 100, message = "服务不能超过100个字符")
    @TableField(value = "`service`", jdbcType = JdbcType.VARCHAR)
    private String service;

    //服务名
    @Size(max = 100, message = "服务名不能超过100个字符")
    @TableField(value = "`service_name`", jdbcType = JdbcType.VARCHAR)
    private String serviceName;

    //接口描述
    @Size(max = 200, message = "接口描述不能超过200个字符")
    @TableField(value = "`interface_desc`", jdbcType = JdbcType.VARCHAR)
    private String interfaceDesc;

    //接口地址
    @Size(max = 200, message = "接口地址不能超过200个字符")
    @TableField(value = "`interface_url`", jdbcType = JdbcType.VARCHAR)
    private String interfaceUrl;

    //接口参数
    @TableField(value = "`interface_param`", jdbcType = JdbcType.CLOB)
    private String interfaceParam;

    //接口方法
    @Size(max = 20, message = "接口方法不能超过20个字符")
    @TableField(value = "`interface_method`", jdbcType = JdbcType.VARCHAR)
    private String interfaceMethod;

    //处理类
    @Size(max = 300, message = "处理类不能超过300个字符")
    @TableField(value = "`clazz`", jdbcType = JdbcType.VARCHAR)
    private String clazz;

    //处理方法
    @Size(max = 100, message = "处理方法不能超过100个字符")
    @TableField(value = "`method`", jdbcType = JdbcType.VARCHAR)
    private String method;

    //返回值
    @TableField(value = "`return_data`", jdbcType = JdbcType.CLOB)
    private String returnData;

    //访问请求ID
    @Size(max = 200, message = "访问请求ID不能超过200个字符")
    @TableField(value = "`trace_id`", jdbcType = JdbcType.VARCHAR)
    private String traceId;

    //访问时间
    @TableField(value = "`invoke_time`", jdbcType = JdbcType.TIMESTAMP)
    private Date invokeTime;

    //访问耗时(毫秒)
    @TableField(value = "`invoke_duration`", jdbcType = JdbcType.BIGINT)
    private Long invokeDuration;

}
